Home

AI API

version 1

The SeaRates Artificial Intelligence API allows you to ask the AI Assistant chat about everything on logistics and get access to a range of Digital Solutions for shipping from the SeaRates ecosystem.

OpenAPI Specification

Start designing your API in minutes. The OpenAPI specification file enables you to learn and interact with API elements, including all available endpoints, input and output representations.

General information

AI API is organized around REST.
Our API has predictable resource-oriented URLs, accepts form-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

API endpoint#

1https://ai-api.searates.com

All endpoints are only accessible via HTTPS and are located at ai-api.searates.com

AI Assistant Chat

post/client/stream

πŸ€– Intelligent Maritime Assistant

Send natural language queries to our AI assistant and receive intelligent, streaming responses about maritime logistics. The AI automatically identifies your intent and provides relevant information from our comprehensive maritime database.

πŸ’‘ Query Examples:

  • Container tracking: "Where is container MSKU7834389?"
  • Vessel information: "Tell me about vessel IMO 9686912"
  • Rate calculations: "What's the freight rate from Shanghai to Long Beach?"
  • Load optimization: "How to pack 50 boxes in a 40ft container?"
  • Market analysis: "Show freight trends for Asia-Europe route"
  • CO2 calculations: "Calculate emissions for 1000 TEU shipment"
  • Distance queries: "Distance from Hamburg to Singapore by sea?"

πŸ”„ Streaming Response: The API returns real-time streaming JSON responses, allowing for immediate data delivery as it becomes available.

Headers

Content-Typeapplication/json

Body Parameters
  • clientIdREQUIREDstring

    πŸ‘€ Client Identifier

    Unique identifier for the client session. Used for conversation context and rate limiting. Should be consistent across requests from the same user/session.

    Examples:client_123456user_session_abc123api_client_xyz789

    Match pattern:^[a-zA-Z0-9_-]+$

  • queryREQUIREDstring

    πŸ’¬ Natural Language Query

    Your question or request in natural language. The AI will automatically understand the intent and provide relevant maritime logistics information.

    Query Types Supported:

    • Container Tracking: "Where is container MSKU7834389?"
    • Vessel Information: "Tell me about vessel IMO 9686912"
    • Rate Calculations: "Freight rate from Shanghai to Rotterdam?"
    • Load Optimization: "Pack 100 boxes in 40ft container"
    • Market Analysis: "Freight trends Asia-Europe route"
    • CO2 Calculations: "CO2 emissions for 500 TEU shipment"
    • Distance Queries: "Sea distance Hamburg to Singapore"
    • General Questions: "What is FCL shipping?"

    Examples:Where is container MSKU7834389?Tell me about vessel IMO 9686912What's the freight rate from Shanghai to Rotterdam for 40ft container?How to pack 100 boxes (60x40x30cm, 10kg each) in containers?Show me freight index trends for Asia-Europe route last monthWhat's the CO2 emission for shipping 500 TEU from Hamburg to New York?Distance and transit time from Singapore to Los Angeles?What's the difference between FCL and LCL shipping?

Request sample
{
  "clientId": "client_123456",
  "query": "Where is container MSKU7834389?"
}
Response example
βœ… **Successful AI Response Stream** The API returns a streaming JSON response with intelligent analysis and data. Response format varies based on query type and may include markdown formatting, tables, charts, and rich content.
1{
2  "response": "SeaRates is a global shipping platform that provides a wide range of services to facilitate international trade and logistics."
3}
1{
2  "response": "πŸ“Š **Freight Index Analysis**\n\nFreight Index: FIX-FCL-AEJEA-KRPUS\nRoute: Jebel Ali, AE β†’ Pusan, KR\nPeriod: 2025-07-01 to 2025-07-31\nCurrent Rate: $278.33\nAverage Rate: $278.33\nRate Range: $278.33 - $278.33\nChange: remained stable by 0%\nData Points: 31 records\n\nπŸ“ˆ **Recent Rate Trends:**\n1. **2025-07-27:** $278.33\n2. **2025-07-28:** $278.33\n3. **2025-07-29:** $278.33\n4. **2025-07-30:** $278.33\n5. **2025-07-31:** $278.33\n\n*Market analysis powered by SeaRates [Freight Index](https://www.searates.com/freight-index/) tool*"
3}
1{
2  "response": "Load calculation completed successfully.\n\nπŸ“¦ **Container Load Optimization Results**\n\nπŸ“‹ **Cargo Specifications:**\nβ€’ **Boxes**: BOX - 60.000 mΒ³, 10kg each\n\nπŸ“¦πŸ“¦β¬†οΈ **Container 1: 40ft High Cube**\nβ”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”\nβ”‚ πŸ“Š **Utilization Summary**              β”‚\nβ”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€\nβ”‚ πŸ”’ **Containers needed**: 1 unit(s)        β”‚\nβ”‚ πŸ“¦ **Total packages**: 12 items         β”‚\nβ”‚ πŸ“ **Volume used**: 0.72 mΒ³ (0.9%)    β”‚\nβ”‚ βš–οΈ  **Weight used**: 120 kg (0.5%)   β”‚\nβ””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜\n\nπŸ“‹ **Items Distribution:**\nβ€’ Boxes: **12 items** loaded\n\n🎯 **Efficiency Analysis:**\nβ€’ ❌ **Low volume utilization** (0.9%) - Consider smaller container\nβ€’ ❌ **Low weight utilization** (0.5%) - Consider optimizing load\n\nπŸ’‘ **Optimization Tips:**\nβ€’ Consider adjusting cargo orientation for better space utilization\nβ€’ Mix different cargo types to optimize both volume and weight\nβ€’ Check if smaller containers might be more cost-effective\n\n*Powered by SeaRates [Container Load Calculator](https://www.searates.com/container-load-calculator/) tool*"
3}
1{
2  "response": "🚒 **Container Tracking Results**\n\nπŸ“¦ **Container**: MSKU7834389\n🏒 **Shipping Line**: Maersk\nπŸ“ **Current Status**: In Transit\n🌍 **Last Location**: Hamburg, Germany\nπŸ“… **Last Update**: 2025-01-15 14:30 UTC\n\nπŸ—ΊοΈ **Journey Timeline:**\n1. **Departure**: Shanghai, China - Jan 1, 2025\n2. **Transit**: Suez Canal - Jan 8, 2025  \n3. **Current**: Hamburg, Germany - Jan 15, 2025\n4. **Expected**: Rotterdam, Netherlands - Jan 18, 2025\n\nπŸ“ˆ **Delivery Status**: On Schedule\n🚚 **Next Update**: Expected in 6 hours\n\n*Real-time tracking powered by SeaRates [Container Tracking](https://www.searates.com/container-tracking/) service*"
3}
1{
2  "response": "🚒 **Vessel Information**\n\n**Basic Details:**\nβ€’ **Name**: JAMAICA EXPRESS\nβ€’ **IMO**: 9686912\nβ€’ **MMSI**: 538005959\nβ€’ **Call Sign**: V7IL5\nβ€’ **Flag**: Marshall Islands (MH)\nβ€’ **Type**: Container Ship\nβ€’ **Built**: 2015\n\n**Specifications:**\nβ€’ **Length**: 271 meters\nβ€’ **Width**: 43 meters\n\nπŸ“ **Current Position (AIS):**\nβ€’ **Location**: 35.87Β°N, -5.53Β°W\nβ€’ **Status**: Moored\nβ€’ **Speed**: 0 knots\nβ€’ **Course**: 135Β°\nβ€’ **Last Update**: 2025-05-23 14:19 UTC\n\nπŸ—ΊοΈ **Voyage Information:**\nβ€’ **From**: Valencia, Spain (ESVLC)\nβ€’ **To**: Tanger Med, Morocco (MAPTM)\nβ€’ **Departure**: May 20, 2025 02:34 UTC\nβ€’ **Arrival**: May 22, 2025 10:12 UTC\n\n*Vessel data powered by SeaRates [Vessel Tracking](https://www.searates.com/vessel-tracking/) service*"
3}